/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * PanelPaso2.java
 *
 * Created on 11-nov-2009, 12:49:06
 */
package pestañas;

import java.awt.Color;
import java.io.BufferedReader;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.InputStreamReader;
import java.net.URL;
import java.net.URLConnection;
import java.text.DecimalFormat;
import utilidades.ValidaBarras;
import javax.swing.JProgressBar;
import javax.swing.JTextField;
import net.java.balloontip.BalloonTip;
import net.java.balloontip.styles.MinimalBalloonStyle;
import net.java.balloontip.utils.TimingUtils;
import utilidades.Booleano;
import utilidades.ValidaDecimal;
import utilidades.ValidaUF;
import vistas.VistaPrincipal;

/**
 *
 * @author Shidobu
 */
public class PanelPaso2 extends javax.swing.JPanel {
	VistaPrincipal vista;
	public JProgressBar barraProgreso;
	float valorUF = (float) 1;//por mientras
	int valorTextField;
	boolean botonUfInternetUsado = false;

	/** Creates new form PanelPaso2 */
	public PanelPaso2 () {
		initComponents ();

	}

	public float getValorUF () {
		return valorUF;
	}

	public void setBarraProgreso (JProgressBar barraProgreso) {
		this.barraProgreso = barraProgreso;
		/*Validar Barra */
		jTextFieldValorUF.addKeyListener (new ValidaUF (jTextFieldValorUF, barraProgreso));
		jTextFieldArriendoOficinaPesos.addKeyListener (new ValidaBarras (jTextFieldArriendoOficinaPesos, barraProgreso));
		jTextFieldGastosOperacionalesPesos.addKeyListener (new ValidaBarras (jTextFieldGastosOperacionalesPesos, barraProgreso));
		jTextFieldGastosMaterialApoyoPesos.addKeyListener (new ValidaBarras (jTextFieldGastosMaterialApoyoPesos, barraProgreso));
		jTextFieldInsumosPesos.addKeyListener (new ValidaBarras (jTextFieldInsumosPesos, barraProgreso));
		jTextFieldGastosBasicosPesos.addKeyListener (new ValidaBarras (jTextFieldGastosBasicosPesos, barraProgreso));
		jTextFieldGastosMovilizacionPesos.addKeyListener (new ValidaBarras (jTextFieldGastosMovilizacionPesos, barraProgreso));
		jTextFieldGastosCoffeBreaksPesos.addKeyListener (new ValidaBarras (jTextFieldGastosCoffeBreaksPesos, barraProgreso));
		jTextFieldGastosAlimentacionPesos.addKeyListener (new ValidaBarras (jTextFieldGastosAlimentacionPesos, barraProgreso));
		jTextFieldGastosServiciosExternosPesos.addKeyListener (new ValidaBarras (jTextFieldGastosServiciosExternosPesos, barraProgreso));
		jTextFieldValorFactorCosto.addKeyListener (new ValidaBarras (jTextFieldValorFactorCosto, barraProgreso));
		jTextFieldHorasReparacion.addKeyListener (new ValidaBarras (jTextFieldHorasReparacion, barraProgreso));
		jTextFieldValorHHDesarrolladorPesos.addKeyListener (new ValidaBarras (jTextFieldValorHHDesarrolladorPesos, barraProgreso));
		jTextFieldValorNumeroDesarrolladores.addKeyListener (new ValidaBarras (jTextFieldValorNumeroDesarrolladores, barraProgreso));



	}

	public void setVista (VistaPrincipal vista) {
		this.vista = vista;
	}

	public void setUF (JTextField jt) {
		if (!(jTextFieldValorUF.getText ().equals ("")) && !jTextFieldValorUF.getText ().equals (".")) {
			try {
				this.valorUF = Float.parseFloat (jt.getText ());
			}
			catch (Exception e) {
				this.valorUF = 1;
			}
		}
		else {
			if (!jt.getText ().equals (""))
			TimingUtils.showTimedBalloon (new BalloonTip (jTextFieldValorUF, "Si el valor empieza con punto, debe indicar decimales",
				new MinimalBalloonStyle (new Color (231, 225, 165), 2), BalloonTip.Orientation.LEFT_ABOVE,
				BalloonTip.AttachLocation.ALIGNED, 20, 10, false), 3000);
		}
	}

	public JProgressBar getBarraProgreso () {
		return barraProgreso;
	}

    public JTextField getJTextFieldArriendoOficinaPesos() {
        return jTextFieldArriendoOficinaPesos;
    }

    public JTextField getJTextFieldArriendoOficinaUF() {
        return jTextFieldArriendoOficinaUF;
    }

    public JTextField getJTextFieldGastosAlimentacionPesos() {
        return jTextFieldGastosAlimentacionPesos;
    }

    public JTextField getJTextFieldGastosAlimentacionUF() {
        return jTextFieldGastosAlimentacionUF;
    }

    public JTextField getJTextFieldGastosBasicosPesos() {
        return jTextFieldGastosBasicosPesos;
    }

    public JTextField getJTextFieldGastosBasicosUF() {
        return jTextFieldGastosBasicosUF;
    }

    public JTextField getJTextFieldGastosCoffeBreaksPesos() {
        return jTextFieldGastosCoffeBreaksPesos;
    }

    public JTextField getJTextFieldGastosCoffeBreaksUF() {
        return jTextFieldGastosCoffeBreaksUF;
    }

    public JTextField getJTextFieldGastosMaterialApoyoPesos() {
        return jTextFieldGastosMaterialApoyoPesos;
    }

    public JTextField getJTextFieldGastosMaterialApoyoUF() {
        return jTextFieldGastosMaterialApoyoUF;
    }

    public JTextField getJTextFieldGastosMovilizacionPesos() {
        return jTextFieldGastosMovilizacionPesos;
    }

    public JTextField getJTextFieldGastosMovilizacionUF() {
        return jTextFieldGastosMovilizacionUF;
    }

    public JTextField getJTextFieldGastosOperacionalesPesos() {
        return jTextFieldGastosOperacionalesPesos;
    }

    public JTextField getJTextFieldGastosOperacionalesUF() {
        return jTextFieldGastosOperacionalesUF;
    }

    public JTextField getJTextFieldGastosServiciosExternosPesos() {
        return jTextFieldGastosServiciosExternosPesos;
    }

    public JTextField getJTextFieldGastosServiciosExternosUF() {
        return jTextFieldGastosServiciosExternosUF;
    }

    public JTextField getJTextFieldGastosTotalPesos() {
        return jTextFieldGastosTotalPesos;
    }

    public JTextField getJTextFieldGastosTotalUF() {
        return jTextFieldGastosTotalUF;
    }

    public JTextField getJTextFieldHorasReparacion() {
        return jTextFieldHorasReparacion;
    }

    public JTextField getJTextFieldInsumosPesos() {
        return jTextFieldInsumosPesos;
    }

    public JTextField getJTextFieldInsumosUF() {
        return jTextFieldInsumosUF;
    }

    public JTextField getJTextFieldTotalCostoPesos() {
        return jTextFieldTotalCostoPesos;
    }

    public JTextField getJTextFieldTotalCostoUF() {
        return jTextFieldTotalCostoUF;
    }

    public JTextField getJTextFieldValorFactorCosto() {
        return jTextFieldValorFactorCosto;
    }

    public JTextField getJTextFieldValorHHDesarrolladorPesos() {
        return jTextFieldValorHHDesarrolladorPesos;
    }

    public JTextField getJTextFieldValorHHDesarrolladorUF() {
        return jTextFieldValorHHDesarrolladorUF;
    }

    public JTextField getJTextFieldValorNumeroDesarrolladores() {
        return jTextFieldValorNumeroDesarrolladores;
    }

    public JTextField getJTextFieldValorUF() {
        return jTextFieldValorUF;
    }

    
    public void calculaUF(JTextField jTFPESOS, JTextField jTFUF) {
        if (!(jTFPESOS.getText().equals(""))) {
            if (jTFPESOS.getText().matches("[0-9]*")) {
                valorTextField = Integer.parseInt(jTFPESOS.getText());
                float resultadoUF = ValidaDecimal.roundNum( ((float) valorTextField) / valorUF );
                jTFUF.setText(String.valueOf(resultadoUF));
            }
        } else //Si el valor de gasto en pesos es nulo, se setea el valor del UF correspondiente
        {
            jTFUF.setText("");
        }

        sumaTotal();// Se calcula la suma total de los gastos tanto en Pesos como en UF


    }

	public void calculaUFes () {
		this.calculaUF (jTextFieldArriendoOficinaPesos, jTextFieldArriendoOficinaUF);
		this.calculaUF (jTextFieldGastosOperacionalesPesos, jTextFieldGastosOperacionalesUF);
		this.calculaUF (jTextFieldGastosMaterialApoyoPesos, jTextFieldGastosMaterialApoyoUF);
		this.calculaUF (jTextFieldInsumosPesos, jTextFieldInsumosUF);
		this.calculaUF (jTextFieldGastosBasicosPesos, jTextFieldGastosBasicosUF);
		this.calculaUF (jTextFieldGastosMovilizacionPesos, jTextFieldGastosMovilizacionUF);
		this.calculaUF (jTextFieldGastosCoffeBreaksPesos, jTextFieldGastosCoffeBreaksUF);
		this.calculaUF (jTextFieldGastosAlimentacionPesos, jTextFieldGastosAlimentacionUF);
		this.calculaUF (jTextFieldGastosServiciosExternosPesos, jTextFieldGastosServiciosExternosUF);
		this.calculaUF (jTextFieldValorHHDesarrolladorPesos, jTextFieldValorHHDesarrolladorUF);

	}

	public void sumaTotal () {
		int totalPesos = 0;//variable que almacena la suma total en PESOS
		float totalUF = 0; //variable que almacena la suma total en UF

		/*A continuacion se verifican los jtextField correspondiente al gasto en PESOS y se suma si es que el valor no es nulo*/
		if (!(jTextFieldArriendoOficinaPesos.getText ()).equals ("")) {
			totalPesos = totalPesos + Integer.parseInt (jTextFieldArriendoOficinaPesos.getText ());
		}

		if (!(jTextFieldGastosOperacionalesPesos.getText ()).equals ("")) {
			totalPesos = totalPesos + Integer.parseInt (jTextFieldGastosOperacionalesPesos.getText ());
		}

		if (!(jTextFieldGastosMaterialApoyoPesos.getText ()).equals ("")) {
			totalPesos = totalPesos + Integer.parseInt (jTextFieldGastosMaterialApoyoPesos.getText ());
		}

		if (!(jTextFieldInsumosPesos.getText ()).equals ("")) {
			totalPesos = totalPesos + Integer.parseInt (jTextFieldInsumosPesos.getText ());
		}

		if (!(jTextFieldGastosBasicosPesos.getText ()).equals ("")) {
			totalPesos = totalPesos + Integer.parseInt (jTextFieldGastosBasicosPesos.getText ());
		}

		if (!(jTextFieldGastosMovilizacionPesos.getText ()).equals ("")) {
			totalPesos = totalPesos + Integer.parseInt (jTextFieldGastosMovilizacionPesos.getText ());
		}

		if (!(jTextFieldGastosCoffeBreaksPesos.getText ()).equals ("")) {
			totalPesos = totalPesos + Integer.parseInt (jTextFieldGastosCoffeBreaksPesos.getText ());
		}

		if (!(jTextFieldGastosAlimentacionPesos.getText ()).equals ("")) {
			totalPesos = totalPesos + Integer.parseInt (jTextFieldGastosAlimentacionPesos.getText ());
		}

		if (!(jTextFieldGastosServiciosExternosPesos.getText ()).equals ("")) {
			totalPesos = totalPesos + Integer.parseInt (jTextFieldGastosServiciosExternosPesos.getText ());
		}

		/*A continuacion se verifican los jtextField correspondiente al gasto en UF y se suma si es que el valor no es nulo*/

		if (!(jTextFieldArriendoOficinaUF.getText ()).equals ("")) {
			totalUF = totalUF + Float.parseFloat (jTextFieldArriendoOficinaUF.getText ());
		}

		if (!(jTextFieldGastosOperacionalesUF.getText ()).equals ("")) {
			totalUF = totalUF + Float.parseFloat (jTextFieldGastosOperacionalesUF.getText ());
		}

		if (!(jTextFieldGastosMaterialApoyoUF.getText ()).equals ("")) {
			totalUF = totalUF + Float.parseFloat (jTextFieldGastosMaterialApoyoUF.getText ());
		}

		if (!(jTextFieldInsumosUF.getText ()).equals ("")) {
			totalUF = totalUF + Float.parseFloat (jTextFieldInsumosUF.getText ());
		}

		if (!(jTextFieldGastosBasicosUF.getText ()).equals ("")) {
			totalUF = totalUF + Float.parseFloat (jTextFieldGastosBasicosUF.getText ());
		}

		if (!(jTextFieldGastosMovilizacionUF.getText ()).equals ("")) {
			totalUF = totalUF + Float.parseFloat (jTextFieldGastosMovilizacionUF.getText ());
		}

		if (!(jTextFieldGastosCoffeBreaksUF.getText ()).equals ("")) {
			totalUF = totalUF + Float.parseFloat (jTextFieldGastosCoffeBreaksUF.getText ());
		}

		if (!(jTextFieldGastosAlimentacionUF.getText ()).equals ("")) {
			totalUF = totalUF + Float.parseFloat (jTextFieldGastosAlimentacionUF.getText ());
		}

		if (!(jTextFieldGastosServiciosExternosUF.getText ()).equals ("")) {
			totalUF = totalUF + Float.parseFloat (jTextFieldGastosServiciosExternosUF.getText ());
		}


		/* Se ingresan los resultados a los jtextfield del TOTAL*/

		jTextFieldGastosTotalPesos.setText (String.valueOf (totalPesos));
		jTextFieldGastosTotalUF.setText (String.valueOf (ValidaDecimal.roundNum(totalUF)));

             /* Se calcula el costo total para el factor costo*/
             if(totalPesos !=0 && !jTextFieldValorFactorCosto.getText().isEmpty() ){
             float totalPeso= Integer.parseInt(jTextFieldGastosTotalPesos.getText())*(Float.parseFloat(jTextFieldValorFactorCosto.getText())/100);
             int totalP= (int)totalPeso;
             jTextFieldTotalCostoPesos.setText(String.valueOf(totalP));
             
             valorTextField = Integer.parseInt ( jTextFieldTotalCostoPesos.getText ());
				float resultadoUF = ValidaDecimal.roundNum( ((float) valorTextField) / valorUF );
				jTextFieldTotalCostoUF.setText (String.valueOf (resultadoUF));
            }

	}


////////////////Para guardar en el Archivo//////////////////////////////////////
        public String retornaArriendo( )
        {
            String Arriendo, enPesos, enUF;
            enPesos = jTextFieldArriendoOficinaPesos.getText ().toString();
            enUF = jTextFieldArriendoOficinaUF.getText().toString();
            if(enPesos.equals(""))
                enPesos = "-1";
            if(enUF.equals(""))
                enUF = "-1";
            Arriendo = enPesos + "#" + enUF;
            return Arriendo;
        }

        public String retornaGastosOP()
        {
            String GastosOP, enPesos, enUF;
            enPesos = jTextFieldGastosOperacionalesPesos.getText ().toString();
            enUF = jTextFieldGastosOperacionalesUF.getText().toString();
            if(enPesos.equals(""))
                enPesos = "-1";
            if(enUF.equals(""))
                enUF = "-1";
            GastosOP = enPesos + "#" + enUF;
            return GastosOP;

        }

        public String retornaGastosMA()
        {
            String GastosMA, enPesos, enUF;
            enPesos = jTextFieldGastosMaterialApoyoPesos.getText ().toString();
            enUF = jTextFieldGastosMaterialApoyoUF.getText().toString();
            if(enPesos.equals(""))
                enPesos = "-1";
            if(enUF.equals(""))
                enUF = "-1";
            GastosMA = enPesos + "#" + enUF;
            return GastosMA;
        }

        public String retornaInsumos()
        {
            String Insumos, enPesos, enUF;
            enPesos = jTextFieldInsumosPesos.getText ().toString();
            enUF = jTextFieldInsumosUF.getText().toString();
            if(enPesos.equals(""))
                enPesos = "-1";
            if(enUF.equals(""))
                enUF = "-1";
            Insumos = enPesos + "#" + enUF;
            return Insumos;
        }

        public String retornaGastosB()
        {
            String GastosB, enPesos, enUF;
            enPesos = jTextFieldGastosBasicosPesos.getText ().toString();
            enUF = jTextFieldGastosBasicosUF.getText().toString();
            if(enPesos.equals(""))
                enPesos = "-1";
            if(enUF.equals(""))
                enUF = "-1";
            GastosB = enPesos + "#" + enUF;
            return GastosB;
        }

        public String retornaGastosMov()
        {
            String GastosMov, enPesos, enUF;
            enPesos = jTextFieldGastosMovilizacionPesos.getText ().toString();
            enUF = jTextFieldGastosMovilizacionUF.getText().toString();
            if(enPesos.equals(""))
                enPesos = "-1";
            if(enUF.equals(""))
                enUF = "-1";
            GastosMov = enPesos + "#" + enUF;
            return GastosMov;
        }

        public String retornaGastosCoffe()
        {
            String GastosCoffe, enPesos, enUF;
            enPesos = jTextFieldGastosCoffeBreaksPesos.getText ().toString();
            enUF = jTextFieldGastosCoffeBreaksUF.getText().toString();
            if(enPesos.equals(""))
                enPesos = "-1";
            if(enUF.equals(""))
                enUF = "-1";
            GastosCoffe = enPesos + "#" + enUF;
            return GastosCoffe;
        }

        public String retornaGastosAlim()
        {
            String GastosAlim, enPesos, enUF;
            enPesos = jTextFieldGastosAlimentacionPesos.getText ().toString();
            enUF = jTextFieldGastosAlimentacionUF.getText().toString();
            if(enPesos.equals(""))
                enPesos = "-1";
            if(enUF.equals(""))
                enUF = "-1";
            GastosAlim = enPesos + "#" + enUF;
            return GastosAlim;
        }

        public String retornaServExt()
        {
            String ServExt, enPesos, enUF;
            enPesos = jTextFieldGastosServiciosExternosPesos.getText ().toString();
            enUF = jTextFieldGastosServiciosExternosUF.getText().toString();
            if(enPesos.equals(""))
                enPesos = "-1";
            if(enUF.equals(""))
                enUF = "-1";
            ServExt = enPesos + "#" + enUF;
            return ServExt;
        }

        public String retornaTotalGastos()
        {
            String TotalGastos, enPesos, enUF;
            enPesos = jTextFieldGastosTotalPesos.getText ().toString();
            enUF = jTextFieldGastosTotalUF.getText().toString();
            if(enPesos.equals(""))
                enPesos = "-1";
            if(enUF.equals(""))
                enUF = "-1";
            TotalGastos = enPesos + "#" + enUF;
            return TotalGastos;
        }

        public String retornaFaseRep()
        {
            String FaseRep, Horas, Desarrolladores, ValorHHenPesos, ValorHHenUF;
            Horas = jTextFieldHorasReparacion.getText().toString();
            Desarrolladores = jTextFieldValorNumeroDesarrolladores.getText().toString();
            ValorHHenPesos = jTextFieldValorHHDesarrolladorPesos.getText().toString();
            ValorHHenUF = jTextFieldValorHHDesarrolladorUF.getText().toString();

            if(Horas.equals(""))
                Horas = "-1";
            if(Desarrolladores.equals(""))
                Desarrolladores = "-1";
            if(ValorHHenPesos.equals(""))
                ValorHHenPesos = "-1";
            if(ValorHHenUF.equals(""))
                ValorHHenUF = "-1";
            FaseRep = Horas + "#" + Desarrolladores + "#" + ValorHHenPesos + "#" + ValorHHenUF;
            return FaseRep;
        }

        public String retornaCostos()
        {
            String CostoTotal, Factor, TotalenPesos, TotalenUF;

            Factor = jTextFieldValorFactorCosto.getText().toString();
            TotalenPesos = jTextFieldTotalCostoPesos.getText().toString();
            TotalenUF = jTextFieldTotalCostoUF.getText().toString();
            if(Factor.equals(""))
                Factor = "-1";
            if(TotalenPesos.equals(""))
                TotalenPesos = "-1";
            if(TotalenUF.equals(""))
                TotalenUF = "-1";

            CostoTotal = Factor + "#" + TotalenPesos + "#" + TotalenUF;
            return CostoTotal;
        }
////////////////////////////////////////////////////////////////////////////////

        //Métodos para ABRIR y para LIMPIAR
        public void setValorUF(String valor){
            this.jTextFieldValorUF.setText(valor);
        }

        public void setHorasReparacion(String valor){
            this.jTextFieldHorasReparacion.setText(valor);
        }

        public void setValorNumeroDesarrolladores(String valor){
            this.jTextFieldValorNumeroDesarrolladores.setText(valor);
        }

        public void setValorHHDesarrolladorPesos(String valor){
            this.jTextFieldValorHHDesarrolladorPesos.setText(valor);
        }

        public void setValorHHDesarrolladorUF(String valor){
            this.jTextFieldValorHHDesarrolladorUF.setText(valor);
        }

        public void setArriendoOficinaPesos(String valor){
            this.jTextFieldArriendoOficinaPesos.setText(valor);
        }

        public void setArriendoOficinaUF(String valor){
            this.jTextFieldArriendoOficinaUF.setText(valor);
        }

        public void setGastosOperacionalesPesos(String valor){
            this.jTextFieldGastosOperacionalesPesos.setText(valor);
        }

        public void setGastosOperacionalesUF(String valor){
            this.jTextFieldGastosOperacionalesUF.setText(valor);
        }

        public void setGastosMaterialApoyoPesos(String valor){
            this.jTextFieldGastosMaterialApoyoPesos.setText(valor);
        }

        public void setGastosMaterialApoyoUF(String valor){
            this.jTextFieldGastosMaterialApoyoUF.setText(valor);
        }

        public void setInsumosPesos(String valor){
            this.jTextFieldInsumosPesos.setText(valor);
        }

        public void setInsumosUF(String valor){
            this.jTextFieldInsumosUF.setText(valor);
        }

        public void setGastosBasicosPesos(String valor){
            this.jTextFieldGastosBasicosPesos.setText(valor);
        }

        public void setGastosBasicosUF(String valor){
            this.jTextFieldGastosBasicosUF.setText(valor);
        }

        public void setGastosMovilizacionPesos(String valor){
            this.jTextFieldGastosMovilizacionPesos.setText(valor);
        }

        public void setGastosMovilizacionUF(String valor){
            this.jTextFieldGastosMovilizacionUF.setText(valor);
        }

        public void setGastosCoffeBreaksPesos(String valor){
            this.jTextFieldGastosCoffeBreaksPesos.setText(valor);
        }

        public void setGastosCoffeBreaksUF(String valor){
            this.jTextFieldGastosCoffeBreaksUF.setText(valor);
        }

        public void setGastosAlimentacionPesos(String valor){
            this.jTextFieldGastosAlimentacionPesos.setText(valor);
        }

        public void setGastosAlimentacionUF(String valor){
            this.jTextFieldGastosAlimentacionUF.setText(valor);
        }

        public void setGastosServiciosExternosPesos(String valor){
            this.jTextFieldGastosServiciosExternosPesos.setText(valor);
        }

        public void setGastosServiciosExternosUF(String valor){
            this.jTextFieldGastosServiciosExternosUF.setText(valor);
        }

        public void setGastosTotalPesos(String valor){
            this.jTextFieldGastosTotalPesos.setText(valor);
        }

        public void setGastosTotalUF(String valor){
            this.jTextFieldGastosTotalUF.setText(valor);
        }

        public void setValorFactorCosto(String valor){
            this.jTextFieldValorFactorCosto.setText(valor);
        }

        public void setTotalCostoPesos(String valor){
            this.jTextFieldTotalCostoPesos.setText(valor);
        }

        public void setTotalCostoUF(String valor){
            this.jTextFieldTotalCostoUF.setText(valor);
        }

	public JTextField getjTextFieldArriendoOficinaPesos () {
		return jTextFieldArriendoOficinaPesos;
	}

	public JTextField getjTextFieldArriendoOficinaUF () {
		return jTextFieldArriendoOficinaUF;
	}

	public JTextField getjTextFieldGastosAlimentacionPesos () {
		return jTextFieldGastosAlimentacionPesos;
	}

	public JTextField getjTextFieldGastosAlimentacionUF () {
		return jTextFieldGastosAlimentacionUF;
	}

	public JTextField getjTextFieldGastosBasicosPesos () {
		return jTextFieldGastosBasicosPesos;
	}

	public JTextField getjTextFieldGastosBasicosUF () {
		return jTextFieldGastosBasicosUF;
	}

	public JTextField getjTextFieldGastosCoffeBreaksPesos () {
		return jTextFieldGastosCoffeBreaksPesos;
	}

	public JTextField getjTextFieldGastosCoffeBreaksUF () {
		return jTextFieldGastosCoffeBreaksUF;
	}

	public JTextField getjTextFieldGastosMaterialApoyoPesos () {
		return jTextFieldGastosMaterialApoyoPesos;
	}

	public JTextField getjTextFieldGastosMaterialApoyoUF () {
		return jTextFieldGastosMaterialApoyoUF;
	}

	public JTextField getjTextFieldGastosMovilizacionPesos () {
		return jTextFieldGastosMovilizacionPesos;
	}

	public JTextField getjTextFieldGastosMovilizacionUF () {
		return jTextFieldGastosMovilizacionUF;
	}

	public JTextField getjTextFieldGastosOperacionalesPesos () {
		return jTextFieldGastosOperacionalesPesos;
	}

	public JTextField getjTextFieldGastosOperacionalesUF () {
		return jTextFieldGastosOperacionalesUF;
	}

	public JTextField getjTextFieldGastosServiciosExternosPesos () {
		return jTextFieldGastosServiciosExternosPesos;
	}

	public JTextField getjTextFieldGastosServiciosExternosUF () {
		return jTextFieldGastosServiciosExternosUF;
	}

	public JTextField getjTextFieldGastosTotalPesos () {
		return jTextFieldGastosTotalPesos;
	}

	public JTextField getjTextFieldGastosTotalUF () {
		return jTextFieldGastosTotalUF;
	}

	public JTextField getjTextFieldHorasReparacion () {
		return jTextFieldHorasReparacion;
	}

	public JTextField getjTextFieldInsumosPesos () {
		return jTextFieldInsumosPesos;
	}

	public JTextField getjTextFieldInsumosUF () {
		return jTextFieldInsumosUF;
	}

	public JTextField getjTextFieldTotalCostoPesos () {
		return jTextFieldTotalCostoPesos;
	}

	public JTextField getjTextFieldTotalCostoUF () {
		return jTextFieldTotalCostoUF;
	}

	public JTextField getjTextFieldValorFactorCosto () {
		return jTextFieldValorFactorCosto;
	}

	public JTextField getjTextFieldValorHHDesarrolladorPesos () {
		return jTextFieldValorHHDesarrolladorPesos;
	}

	public JTextField getjTextFieldValorHHDesarrolladorUF () {
		return jTextFieldValorHHDesarrolladorUF;
	}

	public JTextField getjTextFieldValorNumeroDesarrolladores () {
		return jTextFieldValorNumeroDesarrolladores;
	}

	public JTextField getjTextFieldValorUF () {
		return jTextFieldValorUF;
	}

		

	@SuppressWarnings ("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        jPanelValorUF = new javax.swing.JPanel();
        jLabelIngresoValorUF = new javax.swing.JLabel();
        jTextFieldValorUF = new javax.swing.JTextField();
        jButtonValorUfInternet = new javax.swing.JButton();
        jPanelCostosDiseñoEvaluacionAnalisis = new javax.swing.JPanel();
        jPanelFactorCosto = new javax.swing.JPanel();
        jLabelFactorCosto = new javax.swing.JLabel();
        jTextFieldValorFactorCosto = new javax.swing.JTextField();
        jPanelTotalCosto = new javax.swing.JPanel();
        jLabelTotalCostoPesos = new javax.swing.JLabel();
        jLabelTotalCostosUF = new javax.swing.JLabel();
        jTextFieldTotalCostoPesos = new javax.swing.JTextField();
        jTextFieldTotalCostoUF = new javax.swing.JTextField();
        jPanelGastoItems = new javax.swing.JPanel();
        jLabelArriendoOficina = new javax.swing.JLabel();
        jLabelGastosOperacionales = new javax.swing.JLabel();
        jLabelGastosMaterialApoyo = new javax.swing.JLabel();
        jLabelInsumos = new javax.swing.JLabel();
        jLabelGastosBasicos = new javax.swing.JLabel();
        jLabelGastosMovilizacion = new javax.swing.JLabel();
        jLabelGastosCoffeBreaks = new javax.swing.JLabel();
        jLabelGastosAlimentacion = new javax.swing.JLabel();
        jLabelGastosServiciosExternos = new javax.swing.JLabel();
        jLabelTotalGastos = new javax.swing.JLabel();
        jLabelGastosPesos = new javax.swing.JLabel();
        jLabelGastosUF = new javax.swing.JLabel();
        jTextFieldArriendoOficinaPesos = new javax.swing.JTextField();
        jTextFieldArriendoOficinaUF = new javax.swing.JTextField();
        jTextFieldGastosOperacionalesUF = new javax.swing.JTextField();
        jTextFieldGastosOperacionalesPesos = new javax.swing.JTextField();
        jTextFieldGastosMaterialApoyoUF = new javax.swing.JTextField();
        jTextFieldGastosMaterialApoyoPesos = new javax.swing.JTextField();
        jTextFieldInsumosUF = new javax.swing.JTextField();
        jTextFieldInsumosPesos = new javax.swing.JTextField();
        jTextFieldGastosBasicosUF = new javax.swing.JTextField();
        jTextFieldGastosBasicosPesos = new javax.swing.JTextField();
        jTextFieldGastosMovilizacionUF = new javax.swing.JTextField();
        jTextFieldGastosMovilizacionPesos = new javax.swing.JTextField();
        jTextFieldGastosCoffeBreaksPesos = new javax.swing.JTextField();
        jTextFieldGastosCoffeBreaksUF = new javax.swing.JTextField();
        jTextFieldGastosAlimentacionPesos = new javax.swing.JTextField();
        jTextFieldGastosAlimentacionUF = new javax.swing.JTextField();
        jTextFieldGastosServiciosExternosPesos = new javax.swing.JTextField();
        jTextFieldGastosServiciosExternosUF = new javax.swing.JTextField();
        jTextFieldGastosTotalPesos = new javax.swing.JTextField();
        jTextFieldGastosTotalUF = new javax.swing.JTextField();
        jPanelCostosReparacion = new javax.swing.JPanel();
        jPanelCantidad = new javax.swing.JPanel();
        jLabelHorasReparacion = new javax.swing.JLabel();
        jLabelNumeroDesarrolladores = new javax.swing.JLabel();
        jTextFieldHorasReparacion = new javax.swing.JTextField();
        jTextFieldValorNumeroDesarrolladores = new javax.swing.JTextField();
        jPanelDesarrollador = new javax.swing.JPanel();
        jLabelValorHHDesarrolladorPesos = new javax.swing.JLabel();
        jLabelValorHHDesarrolladorUF = new javax.swing.JLabel();
        jTextFieldValorHHDesarrolladorPesos = new javax.swing.JTextField();
        jTextFieldValorHHDesarrolladorUF = new javax.swing.JTextField();

        setMaximumSize(new java.awt.Dimension(595, 540));
        setMinimumSize(new java.awt.Dimension(595, 540));
        setPreferredSize(new java.awt.Dimension(595, 540));

        jPanelValorUF.setBorder(javax.swing.BorderFactory.createEtchedBorder());

        jLabelIngresoValorUF.setFont(new java.awt.Font("Tahoma", 1, 12));
        jLabelIngresoValorUF.setText("Ingrese el valor de la UF:");

        jTextFieldValorUF.setToolTipText("Ingrese un valor positivo, utilizando punto para los decimales");
        jTextFieldValorUF.setPreferredSize(new java.awt.Dimension(100, 20));
        jTextFieldValorUF.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                jTextFieldValorUFKeyReleased(evt);
            }
        });

        jButtonValorUfInternet.setText("Obtener valor UF vía internet");
        jButtonValorUfInternet.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButtonValorUfInternetActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout jPanelValorUFLayout = new javax.swing.GroupLayout(jPanelValorUF);
        jPanelValorUF.setLayout(jPanelValorUFLayout);
        jPanelValorUFLayout.setHorizontalGroup(
            jPanelValorUFLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelValorUFLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jLabelIngresoValorUF)
                .addGap(18, 18, 18)
                .addComponent(jTextFieldValorUF, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(18, 18, 18)
                .addComponent(jButtonValorUfInternet, javax.swing.GroupLayout.PREFERRED_SIZE, 192, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(84, Short.MAX_VALUE))
        );
        jPanelValorUFLayout.setVerticalGroup(
            jPanelValorUFLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelValorUFLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanelValorUFLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelIngresoValorUF)
                    .addComponent(jTextFieldValorUF, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jButtonValorUfInternet))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        jPanelCostosDiseñoEvaluacionAnalisis.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createEtchedBorder(), "Costos Fase de Diseño, Evaluación y Análisis", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 12))); // NOI18N

        jLabelFactorCosto.setText("Factor Costo (%):");

        jTextFieldValorFactorCosto.setToolTipText("Ingrese un número entre 0 y 100");
        jTextFieldValorFactorCosto.setPreferredSize(new java.awt.Dimension(90, 20));
        jTextFieldValorFactorCosto.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                jTextFieldValorFactorCostoKeyReleased(evt);
            }
        });

        javax.swing.GroupLayout jPanelFactorCostoLayout = new javax.swing.GroupLayout(jPanelFactorCosto);
        jPanelFactorCosto.setLayout(jPanelFactorCostoLayout);
        jPanelFactorCostoLayout.setHorizontalGroup(
            jPanelFactorCostoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelFactorCostoLayout.createSequentialGroup()
                .addComponent(jLabelFactorCosto)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 10, Short.MAX_VALUE)
                .addComponent(jTextFieldValorFactorCosto, javax.swing.GroupLayout.PREFERRED_SIZE, 90, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap())
        );
        jPanelFactorCostoLayout.setVerticalGroup(
            jPanelFactorCostoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelFactorCostoLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanelFactorCostoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelFactorCosto)
                    .addComponent(jTextFieldValorFactorCosto, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        jPanelTotalCosto.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createEtchedBorder(), "Total Costo"));

        jLabelTotalCostoPesos.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        jLabelTotalCostoPesos.setText("En Pesos ($)");
        jLabelTotalCostoPesos.setMaximumSize(new java.awt.Dimension(80, 14));
        jLabelTotalCostoPesos.setMinimumSize(new java.awt.Dimension(80, 14));
        jLabelTotalCostoPesos.setPreferredSize(new java.awt.Dimension(80, 14));

        jLabelTotalCostosUF.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        jLabelTotalCostosUF.setText("En UF");
        jLabelTotalCostosUF.setMaximumSize(new java.awt.Dimension(80, 14));
        jLabelTotalCostosUF.setMinimumSize(new java.awt.Dimension(80, 14));
        jLabelTotalCostosUF.setPreferredSize(new java.awt.Dimension(80, 14));

        jTextFieldTotalCostoPesos.setEnabled(false);
        jTextFieldTotalCostoPesos.setMaximumSize(new java.awt.Dimension(80, 14));
        jTextFieldTotalCostoPesos.setMinimumSize(new java.awt.Dimension(80, 14));
        jTextFieldTotalCostoPesos.setPreferredSize(new java.awt.Dimension(80, 20));

        jTextFieldTotalCostoUF.setEnabled(false);
        jTextFieldTotalCostoUF.setMaximumSize(new java.awt.Dimension(80, 14));
        jTextFieldTotalCostoUF.setMinimumSize(new java.awt.Dimension(80, 14));
        jTextFieldTotalCostoUF.setPreferredSize(new java.awt.Dimension(80, 20));

        javax.swing.GroupLayout jPanelTotalCostoLayout = new javax.swing.GroupLayout(jPanelTotalCosto);
        jPanelTotalCosto.setLayout(jPanelTotalCostoLayout);
        jPanelTotalCostoLayout.setHorizontalGroup(
            jPanelTotalCostoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelTotalCostoLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanelTotalCostoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jTextFieldTotalCostoPesos, javax.swing.GroupLayout.DEFAULT_SIZE, 80, Short.MAX_VALUE)
                    .addComponent(jLabelTotalCostoPesos, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelTotalCostoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabelTotalCostosUF, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldTotalCostoUF, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap())
        );
        jPanelTotalCostoLayout.setVerticalGroup(
            jPanelTotalCostoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelTotalCostoLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanelTotalCostoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelTotalCostoPesos, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabelTotalCostosUF, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addGroup(jPanelTotalCostoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jTextFieldTotalCostoPesos, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldTotalCostoUF, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap())
        );

        jPanelGastoItems.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createEtchedBorder(), "Gasto por ítem"));

        jLabelArriendoOficina.setText("Arriendo de Oficina:");
        jLabelArriendoOficina.setMaximumSize(new java.awt.Dimension(135, 14));
        jLabelArriendoOficina.setMinimumSize(new java.awt.Dimension(135, 14));
        jLabelArriendoOficina.setPreferredSize(new java.awt.Dimension(135, 14));

        jLabelGastosOperacionales.setText("Gastos Operacionales:");
        jLabelGastosOperacionales.setMaximumSize(new java.awt.Dimension(135, 14));
        jLabelGastosOperacionales.setMinimumSize(new java.awt.Dimension(135, 14));
        jLabelGastosOperacionales.setPreferredSize(new java.awt.Dimension(135, 14));

        jLabelGastosMaterialApoyo.setText("Material de Apoyo:");
        jLabelGastosMaterialApoyo.setMaximumSize(new java.awt.Dimension(135, 14));
        jLabelGastosMaterialApoyo.setMinimumSize(new java.awt.Dimension(135, 14));
        jLabelGastosMaterialApoyo.setPreferredSize(new java.awt.Dimension(135, 14));

        jLabelInsumos.setText("Insumos");
        jLabelInsumos.setMaximumSize(new java.awt.Dimension(135, 14));
        jLabelInsumos.setMinimumSize(new java.awt.Dimension(135, 14));
        jLabelInsumos.setPreferredSize(new java.awt.Dimension(135, 14));

        jLabelGastosBasicos.setText("Gastos Básicos");
        jLabelGastosBasicos.setMaximumSize(new java.awt.Dimension(135, 14));
        jLabelGastosBasicos.setMinimumSize(new java.awt.Dimension(135, 14));
        jLabelGastosBasicos.setPreferredSize(new java.awt.Dimension(135, 14));

        jLabelGastosMovilizacion.setText("Gastos por Movilización:");
        jLabelGastosMovilizacion.setMaximumSize(new java.awt.Dimension(135, 14));
        jLabelGastosMovilizacion.setMinimumSize(new java.awt.Dimension(135, 14));
        jLabelGastosMovilizacion.setPreferredSize(new java.awt.Dimension(135, 14));

        jLabelGastosCoffeBreaks.setText("Gastos por Coffe Breaks:");
        jLabelGastosCoffeBreaks.setMaximumSize(new java.awt.Dimension(135, 14));
        jLabelGastosCoffeBreaks.setMinimumSize(new java.awt.Dimension(135, 14));
        jLabelGastosCoffeBreaks.setPreferredSize(new java.awt.Dimension(135, 14));

        jLabelGastosAlimentacion.setText("Gastos por Alimentación:");
        jLabelGastosAlimentacion.setMaximumSize(new java.awt.Dimension(135, 14));
        jLabelGastosAlimentacion.setMinimumSize(new java.awt.Dimension(135, 14));
        jLabelGastosAlimentacion.setPreferredSize(new java.awt.Dimension(135, 14));

        jLabelGastosServiciosExternos.setText("Gastos Servicios Externos:");
        jLabelGastosServiciosExternos.setMaximumSize(new java.awt.Dimension(135, 14));
        jLabelGastosServiciosExternos.setMinimumSize(new java.awt.Dimension(135, 14));
        jLabelGastosServiciosExternos.setPreferredSize(new java.awt.Dimension(135, 14));

        jLabelTotalGastos.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
        jLabelTotalGastos.setText("TOTAL:");
        jLabelTotalGastos.setMaximumSize(new java.awt.Dimension(135, 14));
        jLabelTotalGastos.setMinimumSize(new java.awt.Dimension(135, 14));
        jLabelTotalGastos.setPreferredSize(new java.awt.Dimension(135, 14));

        jLabelGastosPesos.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        jLabelGastosPesos.setText("En Pesos ($)");

        jLabelGastosUF.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        jLabelGastosUF.setText("En UF");

        jTextFieldArriendoOficinaPesos.setToolTipText("Ingrese un número entero positivo");
        jTextFieldArriendoOficinaPesos.setPreferredSize(new java.awt.Dimension(80, 20));
        jTextFieldArriendoOficinaPesos.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                jTextFieldArriendoOficinaPesosKeyReleased(evt);
            }
        });

        jTextFieldArriendoOficinaUF.setEnabled(false);
        jTextFieldArriendoOficinaUF.setPreferredSize(new java.awt.Dimension(80, 20));

        jTextFieldGastosOperacionalesUF.setEnabled(false);
        jTextFieldGastosOperacionalesUF.setPreferredSize(new java.awt.Dimension(80, 20));

        jTextFieldGastosOperacionalesPesos.setToolTipText("Ingrese un número entero positivo");
        jTextFieldGastosOperacionalesPesos.setPreferredSize(new java.awt.Dimension(80, 20));
        jTextFieldGastosOperacionalesPesos.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                jTextFieldGastosOperacionalesPesosKeyReleased(evt);
            }
        });

        jTextFieldGastosMaterialApoyoUF.setEnabled(false);
        jTextFieldGastosMaterialApoyoUF.setPreferredSize(new java.awt.Dimension(80, 20));

        jTextFieldGastosMaterialApoyoPesos.setToolTipText("Ingrese un número entero positivo");
        jTextFieldGastosMaterialApoyoPesos.setPreferredSize(new java.awt.Dimension(80, 20));
        jTextFieldGastosMaterialApoyoPesos.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                jTextFieldGastosMaterialApoyoPesosKeyReleased(evt);
            }
        });

        jTextFieldInsumosUF.setEnabled(false);
        jTextFieldInsumosUF.setPreferredSize(new java.awt.Dimension(80, 20));

        jTextFieldInsumosPesos.setToolTipText("Ingrese un número entero positivo");
        jTextFieldInsumosPesos.setPreferredSize(new java.awt.Dimension(80, 20));
        jTextFieldInsumosPesos.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                jTextFieldInsumosPesosKeyReleased(evt);
            }
        });

        jTextFieldGastosBasicosUF.setEnabled(false);
        jTextFieldGastosBasicosUF.setPreferredSize(new java.awt.Dimension(80, 20));

        jTextFieldGastosBasicosPesos.setToolTipText("Ingrese un número entero positivo");
        jTextFieldGastosBasicosPesos.setPreferredSize(new java.awt.Dimension(80, 20));
        jTextFieldGastosBasicosPesos.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                jTextFieldGastosBasicosPesosKeyReleased(evt);
            }
        });

        jTextFieldGastosMovilizacionUF.setEnabled(false);
        jTextFieldGastosMovilizacionUF.setPreferredSize(new java.awt.Dimension(80, 20));

        jTextFieldGastosMovilizacionPesos.setToolTipText("Ingrese un número entero positivo");
        jTextFieldGastosMovilizacionPesos.setPreferredSize(new java.awt.Dimension(80, 20));
        jTextFieldGastosMovilizacionPesos.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                jTextFieldGastosMovilizacionPesosKeyReleased(evt);
            }
        });

        jTextFieldGastosCoffeBreaksPesos.setToolTipText("Ingrese un número entero positivo");
        jTextFieldGastosCoffeBreaksPesos.setPreferredSize(new java.awt.Dimension(80, 20));
        jTextFieldGastosCoffeBreaksPesos.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                jTextFieldGastosCoffeBreaksPesosKeyReleased(evt);
            }
        });

        jTextFieldGastosCoffeBreaksUF.setEnabled(false);
        jTextFieldGastosCoffeBreaksUF.setPreferredSize(new java.awt.Dimension(80, 20));

        jTextFieldGastosAlimentacionPesos.setToolTipText("Ingrese un número entero positivo");
        jTextFieldGastosAlimentacionPesos.setPreferredSize(new java.awt.Dimension(80, 20));
        jTextFieldGastosAlimentacionPesos.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                jTextFieldGastosAlimentacionPesosKeyReleased(evt);
            }
        });

        jTextFieldGastosAlimentacionUF.setEnabled(false);
        jTextFieldGastosAlimentacionUF.setPreferredSize(new java.awt.Dimension(80, 20));

        jTextFieldGastosServiciosExternosPesos.setToolTipText("Ingrese un número entero positivo");
        jTextFieldGastosServiciosExternosPesos.setPreferredSize(new java.awt.Dimension(80, 20));
        jTextFieldGastosServiciosExternosPesos.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                jTextFieldGastosServiciosExternosPesosKeyReleased(evt);
            }
        });

        jTextFieldGastosServiciosExternosUF.setEnabled(false);
        jTextFieldGastosServiciosExternosUF.setPreferredSize(new java.awt.Dimension(80, 20));

        jTextFieldGastosTotalPesos.setEnabled(false);
        jTextFieldGastosTotalPesos.setPreferredSize(new java.awt.Dimension(80, 20));

        jTextFieldGastosTotalUF.setEnabled(false);
        jTextFieldGastosTotalUF.setPreferredSize(new java.awt.Dimension(80, 20));

        javax.swing.GroupLayout jPanelGastoItemsLayout = new javax.swing.GroupLayout(jPanelGastoItems);
        jPanelGastoItems.setLayout(jPanelGastoItemsLayout);
        jPanelGastoItemsLayout.setHorizontalGroup(
            jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelGastoItemsLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanelGastoItemsLayout.createSequentialGroup()
                        .addGroup(jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                                .addComponent(jLabelGastosBasicos, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 135, Short.MAX_VALUE)
                                .addComponent(jLabelInsumos, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 135, Short.MAX_VALUE)
                                .addComponent(jLabelGastosOperacionales, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 135, Short.MAX_VALUE)
                                .addComponent(jLabelArriendoOficina, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 135, Short.MAX_VALUE))
                            .addComponent(jLabelGastosMovilizacion, javax.swing.GroupLayout.DEFAULT_SIZE, 135, Short.MAX_VALUE)
                            .addComponent(jLabelGastosMaterialApoyo, javax.swing.GroupLayout.DEFAULT_SIZE, 135, Short.MAX_VALUE))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(jPanelGastoItemsLayout.createSequentialGroup()
                                .addGroup(jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                                    .addComponent(jLabelGastosPesos, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                    .addComponent(jTextFieldArriendoOficinaPesos, javax.swing.GroupLayout.DEFAULT_SIZE, 80, Short.MAX_VALUE))
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addGroup(jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                                    .addComponent(jLabelGastosUF, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                    .addComponent(jTextFieldArriendoOficinaUF, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))
                            .addGroup(jPanelGastoItemsLayout.createSequentialGroup()
                                .addComponent(jTextFieldGastosOperacionalesPesos, javax.swing.GroupLayout.DEFAULT_SIZE, 80, Short.MAX_VALUE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jTextFieldGastosOperacionalesUF, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                            .addGroup(jPanelGastoItemsLayout.createSequentialGroup()
                                .addComponent(jTextFieldGastosMaterialApoyoPesos, javax.swing.GroupLayout.DEFAULT_SIZE, 80, Short.MAX_VALUE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jTextFieldGastosMaterialApoyoUF, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                            .addGroup(jPanelGastoItemsLayout.createSequentialGroup()
                                .addComponent(jTextFieldInsumosPesos, javax.swing.GroupLayout.DEFAULT_SIZE, 80, Short.MAX_VALUE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jTextFieldInsumosUF, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                            .addGroup(jPanelGastoItemsLayout.createSequentialGroup()
                                .addComponent(jTextFieldGastosBasicosPesos, javax.swing.GroupLayout.DEFAULT_SIZE, 80, Short.MAX_VALUE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jTextFieldGastosBasicosUF, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                            .addGroup(jPanelGastoItemsLayout.createSequentialGroup()
                                .addComponent(jTextFieldGastosMovilizacionPesos, javax.swing.GroupLayout.DEFAULT_SIZE, 80, Short.MAX_VALUE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jTextFieldGastosMovilizacionUF, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))))
                    .addGroup(jPanelGastoItemsLayout.createSequentialGroup()
                        .addComponent(jLabelGastosCoffeBreaks, javax.swing.GroupLayout.PREFERRED_SIZE, 135, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jTextFieldGastosCoffeBreaksPesos, javax.swing.GroupLayout.DEFAULT_SIZE, 81, Short.MAX_VALUE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jTextFieldGastosCoffeBreaksUF, javax.swing.GroupLayout.DEFAULT_SIZE, 81, Short.MAX_VALUE))
                    .addGroup(jPanelGastoItemsLayout.createSequentialGroup()
                        .addComponent(jLabelGastosAlimentacion, javax.swing.GroupLayout.PREFERRED_SIZE, 135, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jTextFieldGastosAlimentacionPesos, javax.swing.GroupLayout.DEFAULT_SIZE, 81, Short.MAX_VALUE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jTextFieldGastosAlimentacionUF, javax.swing.GroupLayout.DEFAULT_SIZE, 81, Short.MAX_VALUE))
                    .addGroup(jPanelGastoItemsLayout.createSequentialGroup()
                        .addComponent(jLabelGastosServiciosExternos, javax.swing.GroupLayout.PREFERRED_SIZE, 135, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jTextFieldGastosServiciosExternosPesos, javax.swing.GroupLayout.DEFAULT_SIZE, 81, Short.MAX_VALUE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jTextFieldGastosServiciosExternosUF, javax.swing.GroupLayout.DEFAULT_SIZE, 81, Short.MAX_VALUE))
                    .addGroup(jPanelGastoItemsLayout.createSequentialGroup()
                        .addComponent(jLabelTotalGastos, javax.swing.GroupLayout.PREFERRED_SIZE, 129, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(jTextFieldGastosTotalPesos, javax.swing.GroupLayout.DEFAULT_SIZE, 81, Short.MAX_VALUE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jTextFieldGastosTotalUF, javax.swing.GroupLayout.DEFAULT_SIZE, 81, Short.MAX_VALUE)))
                .addContainerGap())
        );
        jPanelGastoItemsLayout.setVerticalGroup(
            jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanelGastoItemsLayout.createSequentialGroup()
                .addGroup(jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelGastosPesos)
                    .addComponent(jLabelGastosUF))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 7, Short.MAX_VALUE)
                .addGroup(jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelArriendoOficina, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldArriendoOficinaPesos, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldArriendoOficinaUF, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelGastosOperacionales, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldGastosOperacionalesPesos, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldGastosOperacionalesUF, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelGastosMaterialApoyo, javax.swing.GroupLayout.PREFERRED_SIZE, 17, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldGastosMaterialApoyoPesos, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldGastosMaterialApoyoUF, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelInsumos, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldInsumosPesos, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldInsumosUF, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelGastosBasicos, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldGastosBasicosPesos, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldGastosBasicosUF, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jTextFieldGastosMovilizacionPesos, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldGastosMovilizacionUF, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabelGastosMovilizacion, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelGastosCoffeBreaks, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldGastosCoffeBreaksPesos, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldGastosCoffeBreaksUF, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelGastosAlimentacion, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldGastosAlimentacionPesos, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldGastosAlimentacionUF, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelGastosServiciosExternos, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldGastosServiciosExternosPesos, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldGastosServiciosExternosUF, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelGastoItemsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelTotalGastos, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldGastosTotalPesos, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldGastosTotalUF, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap())
        );

        javax.swing.GroupLayout jPanelCostosDiseñoEvaluacionAnalisisLayout = new javax.swing.GroupLayout(jPanelCostosDiseñoEvaluacionAnalisis);
        jPanelCostosDiseñoEvaluacionAnalisis.setLayout(jPanelCostosDiseñoEvaluacionAnalisisLayout);
        jPanelCostosDiseñoEvaluacionAnalisisLayout.setHorizontalGroup(
            jPanelCostosDiseñoEvaluacionAnalisisLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanelCostosDiseñoEvaluacionAnalisisLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jPanelGastoItems, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelCostosDiseñoEvaluacionAnalisisLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jPanelTotalCosto, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jPanelFactorCosto, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addContainerGap())
        );
        jPanelCostosDiseñoEvaluacionAnalisisLayout.setVerticalGroup(
            jPanelCostosDiseñoEvaluacionAnalisisLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelCostosDiseñoEvaluacionAnalisisLayout.createSequentialGroup()
                .addGroup(jPanelCostosDiseñoEvaluacionAnalisisLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanelCostosDiseñoEvaluacionAnalisisLayout.createSequentialGroup()
                        .addComponent(jPanelFactorCosto, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jPanelTotalCosto, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addComponent(jPanelGastoItems, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(16, Short.MAX_VALUE))
        );

        jPanelCostosReparacion.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createEtchedBorder(), "Costos por Fase de Reparación", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 12))); // NOI18N

        jPanelCantidad.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createEtchedBorder(), "Cantidad"));

        jLabelHorasReparacion.setText("Horas de Reparación:");

        jLabelNumeroDesarrolladores.setText("Número de desarrolladores:");

        jTextFieldHorasReparacion.setToolTipText("Ingrese un número entero positivo");
        jTextFieldHorasReparacion.setMaximumSize(new java.awt.Dimension(100, 20));
        jTextFieldHorasReparacion.setMinimumSize(new java.awt.Dimension(100, 20));
        jTextFieldHorasReparacion.setPreferredSize(new java.awt.Dimension(100, 20));

        jTextFieldValorNumeroDesarrolladores.setToolTipText("Ingrese un número entero positivo");
        jTextFieldValorNumeroDesarrolladores.setMaximumSize(new java.awt.Dimension(100, 20));
        jTextFieldValorNumeroDesarrolladores.setMinimumSize(new java.awt.Dimension(100, 20));
        jTextFieldValorNumeroDesarrolladores.setPreferredSize(new java.awt.Dimension(100, 20));

        javax.swing.GroupLayout jPanelCantidadLayout = new javax.swing.GroupLayout(jPanelCantidad);
        jPanelCantidad.setLayout(jPanelCantidadLayout);
        jPanelCantidadLayout.setHorizontalGroup(
            jPanelCantidadLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelCantidadLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanelCantidadLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabelHorasReparacion, javax.swing.GroupLayout.DEFAULT_SIZE, 171, Short.MAX_VALUE)
                    .addComponent(jLabelNumeroDesarrolladores, javax.swing.GroupLayout.DEFAULT_SIZE, 171, Short.MAX_VALUE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelCantidadLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                    .addComponent(jTextFieldValorNumeroDesarrolladores, 0, 0, Short.MAX_VALUE)
                    .addComponent(jTextFieldHorasReparacion, javax.swing.GroupLayout.PREFERRED_SIZE, 88, Short.MAX_VALUE))
                .addContainerGap())
        );
        jPanelCantidadLayout.setVerticalGroup(
            jPanelCantidadLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelCantidadLayout.createSequentialGroup()
                .addGroup(jPanelCantidadLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelHorasReparacion)
                    .addComponent(jTextFieldHorasReparacion, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(jPanelCantidadLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelNumeroDesarrolladores)
                    .addComponent(jTextFieldValorNumeroDesarrolladores, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        jPanelDesarrollador.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createEtchedBorder(), "Valor HH Desarrollador"));

        jLabelValorHHDesarrolladorPesos.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        jLabelValorHHDesarrolladorPesos.setText("En Pesos ($)");

        jLabelValorHHDesarrolladorUF.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        jLabelValorHHDesarrolladorUF.setText("En UF");

        jTextFieldValorHHDesarrolladorPesos.setToolTipText("Ingrese un número entero positivo");
        jTextFieldValorHHDesarrolladorPesos.setPreferredSize(new java.awt.Dimension(80, 20));
        jTextFieldValorHHDesarrolladorPesos.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                jTextFieldValorHHDesarrolladorPesosKeyReleased(evt);
            }
        });

        jTextFieldValorHHDesarrolladorUF.setEnabled(false);
        jTextFieldValorHHDesarrolladorUF.setPreferredSize(new java.awt.Dimension(80, 20));

        javax.swing.GroupLayout jPanelDesarrolladorLayout = new javax.swing.GroupLayout(jPanelDesarrollador);
        jPanelDesarrollador.setLayout(jPanelDesarrolladorLayout);
        jPanelDesarrolladorLayout.setHorizontalGroup(
            jPanelDesarrolladorLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelDesarrolladorLayout.createSequentialGroup()
                .addGap(30, 30, 30)
                .addGroup(jPanelDesarrolladorLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addComponent(jTextFieldValorHHDesarrolladorPesos, javax.swing.GroupLayout.DEFAULT_SIZE, 81, Short.MAX_VALUE)
                    .addComponent(jLabelValorHHDesarrolladorPesos, javax.swing.GroupLayout.DEFAULT_SIZE, 81, Short.MAX_VALUE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelDesarrolladorLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabelValorHHDesarrolladorUF, javax.swing.GroupLayout.DEFAULT_SIZE, 81, Short.MAX_VALUE)
                    .addComponent(jTextFieldValorHHDesarrolladorUF, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, 81, Short.MAX_VALUE))
                .addGap(32, 32, 32))
        );
        jPanelDesarrolladorLayout.setVerticalGroup(
            jPanelDesarrolladorLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanelDesarrolladorLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanelDesarrolladorLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelValorHHDesarrolladorPesos, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabelValorHHDesarrolladorUF))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addGroup(jPanelDesarrolladorLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jTextFieldValorHHDesarrolladorUF, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldValorHHDesarrolladorPesos, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap())
        );

        javax.swing.GroupLayout jPanelCostosReparacionLayout = new javax.swing.GroupLayout(jPanelCostosReparacion);
        jPanelCostosReparacion.setLayout(jPanelCostosReparacionLayout);
        jPanelCostosReparacionLayout.setHorizontalGroup(
            jPanelCostosReparacionLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelCostosReparacionLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jPanelCantidad, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jPanelDesarrollador, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addContainerGap())
        );
        jPanelCostosReparacionLayout.setVerticalGroup(
            jPanelCostosReparacionLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelCostosReparacionLayout.createSequentialGroup()
                .addGroup(jPanelCostosReparacionLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addComponent(jPanelDesarrollador, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jPanelCantidad, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap())
        );

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
        this.setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jPanelValorUF, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jPanelCostosDiseñoEvaluacionAnalisis, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jPanelCostosReparacion, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addContainerGap())
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jPanelValorUF, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jPanelCostosDiseñoEvaluacionAnalisis, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jPanelCostosReparacion, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
    }// </editor-fold>//GEN-END:initComponents

    private void jTextFieldGastosOperacionalesPesosKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldGastosOperacionalesPesosKeyReleased
		this.calculaUF (jTextFieldGastosOperacionalesPesos, jTextFieldGastosOperacionalesUF);
    }//GEN-LAST:event_jTextFieldGastosOperacionalesPesosKeyReleased

    private void jTextFieldGastosMaterialApoyoPesosKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldGastosMaterialApoyoPesosKeyReleased
		this.calculaUF (jTextFieldGastosMaterialApoyoPesos, jTextFieldGastosMaterialApoyoUF);
    }//GEN-LAST:event_jTextFieldGastosMaterialApoyoPesosKeyReleased

    private void jTextFieldInsumosPesosKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldInsumosPesosKeyReleased
		this.calculaUF (jTextFieldInsumosPesos, jTextFieldInsumosUF);
    }//GEN-LAST:event_jTextFieldInsumosPesosKeyReleased

    private void jTextFieldGastosBasicosPesosKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldGastosBasicosPesosKeyReleased
		this.calculaUF (jTextFieldGastosBasicosPesos, jTextFieldGastosBasicosUF);
    }//GEN-LAST:event_jTextFieldGastosBasicosPesosKeyReleased

    private void jTextFieldGastosMovilizacionPesosKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldGastosMovilizacionPesosKeyReleased
		this.calculaUF (jTextFieldGastosMovilizacionPesos, jTextFieldGastosMovilizacionUF);
    }//GEN-LAST:event_jTextFieldGastosMovilizacionPesosKeyReleased

    private void jTextFieldGastosCoffeBreaksPesosKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldGastosCoffeBreaksPesosKeyReleased
		this.calculaUF (jTextFieldGastosCoffeBreaksPesos, jTextFieldGastosCoffeBreaksUF);
    }//GEN-LAST:event_jTextFieldGastosCoffeBreaksPesosKeyReleased

    private void jTextFieldGastosAlimentacionPesosKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldGastosAlimentacionPesosKeyReleased
		this.calculaUF (jTextFieldGastosAlimentacionPesos, jTextFieldGastosAlimentacionUF);
    }//GEN-LAST:event_jTextFieldGastosAlimentacionPesosKeyReleased

    private void jTextFieldGastosServiciosExternosPesosKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldGastosServiciosExternosPesosKeyReleased
		this.calculaUF (jTextFieldGastosServiciosExternosPesos, jTextFieldGastosServiciosExternosUF);
    }//GEN-LAST:event_jTextFieldGastosServiciosExternosPesosKeyReleased

    private void jTextFieldArriendoOficinaPesosKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldArriendoOficinaPesosKeyReleased
		this.calculaUF (jTextFieldArriendoOficinaPesos, jTextFieldArriendoOficinaUF);
    }//GEN-LAST:event_jTextFieldArriendoOficinaPesosKeyReleased

    private void jTextFieldValorUFKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldValorUFKeyReleased
		this.setUF (jTextFieldValorUF);//Se instancia el valor de la UF
            /* al existir un cambio, se calculan los gastos en UF*/
		calculaUFes ();
    }//GEN-LAST:event_jTextFieldValorUFKeyReleased

    private void jTextFieldValorHHDesarrolladorPesosKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldValorHHDesarrolladorPesosKeyReleased
		this.calculaUF (jTextFieldValorHHDesarrolladorPesos, jTextFieldValorHHDesarrolladorUF);
    }//GEN-LAST:event_jTextFieldValorHHDesarrolladorPesosKeyReleased

	private void jButtonValorUfInternetActionPerformed (java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButtonValorUfInternetActionPerformed
		try {
			if (jTextFieldValorUF.getText ().equals ("") && botonUfInternetUsado) {
				botonUfInternetUsado = false;
			}
			URL url = new URL ("http://www.economiaynegocios.cl");
			URLConnection urlc = url.openConnection ();
			InputStream is = urlc.getInputStream ();
			urlc = null;
			url = null;
			BufferedReader bf = new BufferedReader (new InputStreamReader (is));
			String linea;
			while (!(linea = bf.readLine ()).matches (".*UF.*"));
			for (int i = 0; i < 4; i++) {
				linea = bf.readLine ();
			}
			linea = linea.replaceAll ("[^0123456789,]", "");
			linea = linea.replace (",", ".");
			double a = Double.parseDouble (linea);
			jTextFieldValorUF.setText (String.valueOf (a));
			this.setUF (jTextFieldValorUF);
			if (!botonUfInternetUsado) {
				barraProgreso.setValue (barraProgreso.getValue () + 1);
				botonUfInternetUsado = true;
			}
			calculaUFes ();
		}
		catch (Exception ex) {
			TimingUtils.showTimedBalloon (new BalloonTip (jButtonValorUfInternet, "Ocurrió un problema al intentar conectarse con " +
				"el servidor de indicadores económicos",new MinimalBalloonStyle (new Color (231, 225, 165), 2), BalloonTip.Orientation.RIGHT_ABOVE,
				BalloonTip.AttachLocation.ALIGNED, 20, 10, false), 5000);
		}
	}//GEN-LAST:event_jButtonValorUfInternetActionPerformed

        private void jTextFieldValorFactorCostoKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldValorFactorCostoKeyReleased
          /* Se calcula el costo total para el factor costo*/
             if(!jTextFieldGastosTotalPesos.getText().isEmpty() ){
             float totalPeso= Integer.parseInt(jTextFieldGastosTotalPesos.getText())*(Float.parseFloat(jTextFieldValorFactorCosto.getText())/100);
             int totalP= (int)totalPeso;
             jTextFieldTotalCostoPesos.setText(String.valueOf(totalP));

             valorTextField = Integer.parseInt ( jTextFieldTotalCostoPesos.getText ());
				float resultadoUF = ValidaDecimal.roundNum(((float) valorTextField) / valorUF);
				jTextFieldTotalCostoUF.setText (String.valueOf (resultadoUF));
            }

        }//GEN-LAST:event_jTextFieldValorFactorCostoKeyReleased

    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton jButtonValorUfInternet;
    private javax.swing.JLabel jLabelArriendoOficina;
    private javax.swing.JLabel jLabelFactorCosto;
    private javax.swing.JLabel jLabelGastosAlimentacion;
    private javax.swing.JLabel jLabelGastosBasicos;
    private javax.swing.JLabel jLabelGastosCoffeBreaks;
    private javax.swing.JLabel jLabelGastosMaterialApoyo;
    private javax.swing.JLabel jLabelGastosMovilizacion;
    private javax.swing.JLabel jLabelGastosOperacionales;
    private javax.swing.JLabel jLabelGastosPesos;
    private javax.swing.JLabel jLabelGastosServiciosExternos;
    private javax.swing.JLabel jLabelGastosUF;
    private javax.swing.JLabel jLabelHorasReparacion;
    private javax.swing.JLabel jLabelIngresoValorUF;
    private javax.swing.JLabel jLabelInsumos;
    private javax.swing.JLabel jLabelNumeroDesarrolladores;
    private javax.swing.JLabel jLabelTotalCostoPesos;
    private javax.swing.JLabel jLabelTotalCostosUF;
    private javax.swing.JLabel jLabelTotalGastos;
    private javax.swing.JLabel jLabelValorHHDesarrolladorPesos;
    private javax.swing.JLabel jLabelValorHHDesarrolladorUF;
    private javax.swing.JPanel jPanelCantidad;
    private javax.swing.JPanel jPanelCostosDiseñoEvaluacionAnalisis;
    private javax.swing.JPanel jPanelCostosReparacion;
    private javax.swing.JPanel jPanelDesarrollador;
    private javax.swing.JPanel jPanelFactorCosto;
    private javax.swing.JPanel jPanelGastoItems;
    private javax.swing.JPanel jPanelTotalCosto;
    private javax.swing.JPanel jPanelValorUF;
    private javax.swing.JTextField jTextFieldArriendoOficinaPesos;
    private javax.swing.JTextField jTextFieldArriendoOficinaUF;
    private javax.swing.JTextField jTextFieldGastosAlimentacionPesos;
    private javax.swing.JTextField jTextFieldGastosAlimentacionUF;
    private javax.swing.JTextField jTextFieldGastosBasicosPesos;
    private javax.swing.JTextField jTextFieldGastosBasicosUF;
    private javax.swing.JTextField jTextFieldGastosCoffeBreaksPesos;
    private javax.swing.JTextField jTextFieldGastosCoffeBreaksUF;
    private javax.swing.JTextField jTextFieldGastosMaterialApoyoPesos;
    private javax.swing.JTextField jTextFieldGastosMaterialApoyoUF;
    private javax.swing.JTextField jTextFieldGastosMovilizacionPesos;
    private javax.swing.JTextField jTextFieldGastosMovilizacionUF;
    private javax.swing.JTextField jTextFieldGastosOperacionalesPesos;
    private javax.swing.JTextField jTextFieldGastosOperacionalesUF;
    private javax.swing.JTextField jTextFieldGastosServiciosExternosPesos;
    private javax.swing.JTextField jTextFieldGastosServiciosExternosUF;
    private javax.swing.JTextField jTextFieldGastosTotalPesos;
    private javax.swing.JTextField jTextFieldGastosTotalUF;
    private javax.swing.JTextField jTextFieldHorasReparacion;
    private javax.swing.JTextField jTextFieldInsumosPesos;
    private javax.swing.JTextField jTextFieldInsumosUF;
    private javax.swing.JTextField jTextFieldTotalCostoPesos;
    private javax.swing.JTextField jTextFieldTotalCostoUF;
    private javax.swing.JTextField jTextFieldValorFactorCosto;
    private javax.swing.JTextField jTextFieldValorHHDesarrolladorPesos;
    private javax.swing.JTextField jTextFieldValorHHDesarrolladorUF;
    private javax.swing.JTextField jTextFieldValorNumeroDesarrolladores;
    private javax.swing.JTextField jTextFieldValorUF;
    // End of variables declaration//GEN-END:variables
}
